<?php

/**
 * Root Graphing Class
 * @package Nina
 * @author John Main <john@thedaddy.org>
 */
abstract class Nina_Graph
{
	/**
	 * Graph title
	 * @access protected
	 * @var string
	 */
	protected $title = '';

	/**
	 * Graph data
	 * @access protected
	 * @var array
	 */
	protected $data = array();

	/**
	 * Graph object
	 * @access protected
	 * @var Nina_Graph_Jpgraph|Nina_Graph_Highcharts
	 */
	protected $graph;
				
	/**
	 * Constructor
	 */
	public function __construct() {
		
	}

	/**
	 * Set the title
	 * @param string $title The title
	 */
	public function setTitle($title) {
		$this->title = $title;
	}

	/**
	 * Get the title
	 * @return string
	 */
	public function getTitle() {
		return $this->title;
	}
	
	/**
	 * Set the data
	 * @param array $datax The x axis data
	 * @param array [$datay=null] The y axis data
	 */
	public function setData($datax, $datay = null) {
		$this->data = array($datax, $datay);
	}
	
	/**
	 * Get the data
	 * @return array
	 */
	public function getData() {
		return $this->data;
	}
}
